<table width="99%" cellpadding="0" cellspacing="0">
	<tr>
		<td width="<?php echo(isset($codeAuth) and $codeAuth==1)?'190':'230';?>">&nbsp;</td>
		<td align="center">
			<img src="<?php echo BABILI_URL;?>/img/babili_banner.jpg" alt="Talend - Babili" />
		</td>
		<td valign="middle" align="right" width="230">
		 <?php 
			 if(isset($codeAuth) and $codeAuth==1){
		 		$isCanViewStaticsV=false;
				if($_SESSION['groupe']=="staff"||$_SESSION['groupe']=="admin" || $_SESSION['groupe']=="editor"){
					$isCanViewStaticsV=true;
				}
				echo '<table cellpadding="0" cellspacing="0">
						<tr>
							<td>
								<div class="bulk">
									<a href="export_babili.php" title="export babili">
										<br/><strong>Bulk</strong>
									</a>
								</div>
							</td>
							<td>
								<div class="guidelines">
									<a href="#" onclick="javascript:ShowMasque(\'cacherTout\'); cacheGuidelines(false); ChangeClassName(\'table_guide_line1\',\'box_module_table\'); ChangeClassName(\'table_guide_line2\',\'box_module_table\'); return false;" alt="Guidelines" title="Guidelines" target="_blank">
										<br/><strong>Guidelines</strong>
									</a>
								</div>
							</td>
							<td>&nbsp;&nbsp;&nbsp;</td>
							<td>
								<div class="mod_login_logout">
									<a href="logout.php" alt="Logout" title="Logout">
										<br/><strong>Logout</strong>
									</a>
								</div>
							</td>
							<td>&nbsp;&nbsp;</td>
						</tr>
						<tr>
						  <td colspan="5">
						  	<fieldset title="Level" id="loginLevel">
							  <legend align="top"><strong>Login:</strong></legend>'. 
						  	$auth->getIdentity()."&nbsp;";
							
							if($_SESSION['groupe']=="admin"){
								for($j=0; $j<3;$j++){
									echo '<img src="img/award_star_gold_2.png" width="16" height="16">';
								}
							}elseif($_SESSION['groupe']=="editor" || $_SESSION['groupe']=="staff"){	
								for($j=0; $j<2;$j++){
									echo '<img src="img/award_star_gold_2.png" width="16" height="16">';										
								}
							}else{
								echo '<img src="img/award_star_gold_2.png" width="16" height="16">';
							}								
						echo '
							</fieldset>
						  </td>
						</tr>
						
						<tr>
						 <td colspan="5">
							 <!--Select Stats-->
							 <fieldset title="Statistics" id="legStats">
							  <legend align="top"><strong>Statistics:</strong></legend>				   
								<select id="translated_sent" onfocus="calculStats(\'translated\');">
									<option>'._TRANSLATED.'</option>'.
									echoSentences($resultTranslated).'
								</select>';
								
						 	if($isCanViewStaticsV): 
								echo '
								<select id="validated_sent" onfocus="calculStats(\'validated\');">
									<option>'._VALIDATED.'</option>'
									.echoSentences($resultValidated).'
								</select>';
							endif;
						echo '</fieldset>
						 </td>
						</tr>					
					 </table>
					';
			 }
			 
			if (basename($_SERVER['SCRIPT_FILENAME']) == 'export_babili.php') {
			  echo '
			  <table>
				<tr>
				  <td>
					<div class="babili_remote">
					  <a href="./download/babili_remote.zip" title="Download Babili Remote">
						 <br/><strong>Babili Remote</strong>
					  </a>
					</div>
				  </td>
				  <td>
					<div class="guidelines">
					  <a href="http://talendforge.org/tutorials/tutorial.php?language=english&idTuto=18"alt="Guidelines" title="Tutorial for Babili in bulk mode" target="_blank">
						<br/><strong>Tutorial</strong>
					  </a>
					</div>
				  </td>
				</tr>
			  </table>
			';
			}
		 ?>
		</td>
	</tr>
</table>